/**
 * @Author: Wang chunsheng  email:2192138785@qq.com
 * @Date:   2024-03-18 12:11:43
 * @Last Modified by:   Wang chunsheng  email:2192138785@qq.com
 * @Last Modified time: 2024-03-18 22:34:23
 */

import request from '@/projects/shop/utils/request'

export function msgTemplateInitList(data) {
  return request({
    url: '/officialaccount/msg-template/index',
    method: 'get',
    params: data
  })
}

export function msgTemplateGetView(id) {
  return request({
    url: `/officialaccount/msg-template/${id}`,
    method: 'get'
  })
}

export function msgTemplateItemCreate(data) {
  return request({
    url: '/officialaccount/msg-template/create',
    method: 'post',
    data: data
  })
}

export function msgTemplateItemUpdate(id, data) {
  return request({
    url: `/officialaccount/msg-template/update/${id}`,
    method: 'put',
    data: data
  })
}

export function msgTemplateItemDelete(id) {
  return request({
    url: `/officialaccount/msg-template/delete/${id}`,
    method: 'delete'
  })
}

export function msgTemplateGetData(data) {
  return request({
    url: `/officialaccount/msg-template/data`,
    method: 'post',
    data: data
  })
}

export function msgTemplateSetIndustry(data) {
  return request({
    url: '/officialaccount/template/set-industry',
    method: 'post'
  })
}

export function msgTemplateGetIndustry() {
  return request({
    url: '/officialaccount/template/get-industry',
    method: 'get'
  })
}

export function msgTemplateAddTemplate() {
  return request({
    url: '/officialaccount/template/AddTemplate',
    method: 'get'
  })
}

export function GetPrivateTemplates() {
  return request({
    url: '/officialaccount/template/GetPrivateTemplates',
    method: 'get'
  })
}

export function msgTemplateDelPrivateTemplate(data) {
  return request({
    url: '/officialaccount/template/DelPrivateTemplate',
    method: 'post',
    data: data
  })
}

export function msgTemplateSyncWxTemplate(data) {
  return request({
    url: '/officialaccount/template/sync-wx-template',
    method: 'post',
    data: data
  })
}

